﻿<Controls:SinacorWindow
	xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
	xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
	xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
	xmlns:Custom="http://schemas.xceed.com/wpf/xaml/datagrid"
	xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
	mc:Ignorable="d"
	xmlns:Controls="clr-namespace:Sinacor.Infra.UI.Controls.SmartClient;assembly=Sinacor.Infra.UI.Controls"
	
	WindowStartupLocation="CenterScreen"
    WindowState="Maximized"
	Title="{DynamicResource Bovespa.Alocacao.Label.ConsultaNegociosAnulados}"
	
	x:Class="Sinacor.UI.Bovespa.Alocacao.View.SmartClient.ConsultaNegociosAnulados"
    ModulePlus="true"
    ModuleId="ORD">

    <Grid HorizontalAlignment="Stretch" VerticalAlignment="Stretch">
        <Controls:SinacorExpanderContainer Width="Auto" Height="Auto">
            <Controls:SinacorExpanderContainer.RowDefinitions>
                <RowDefinition Height="65" />
                <RowDefinition Height="*" />
            </Controls:SinacorExpanderContainer.RowDefinitions>
            <Controls:SinacorExpander Grid.Row="0"
									  HorizontalAlignment="Stretch"
									  VerticalAlignment="Stretch"
									  Header="{DynamicResource Bovespa.Alocacao.Label.Pesquisa}"
									  IsExpanded="True" 
									  Height="Auto">
                <Grid>
                    <Controls:SinacorLabel HorizontalAlignment="Left" 
					  	Content="{DynamicResource Bovespa.Alocacao.Label.DataPregao}" 
					  	Width="205"
						IsTargetFieldRequired="True" />
                    <Controls:SinacorComboBox IsSynchronizedWithCurrentItem="True" 
					  	HorizontalAlignment="Left" 
						Margin="209,0,0,0" 
						VerticalAlignment="Top" 
						Width="125" 
						WidthPopup="300"
						TabIndex="1"
                        x:Name="cmbDataPregao"
                        ItemsSource="{Binding ListaDataPregao}"
                        DisplayMemberPath="DataPregaoFormatada"
                        SelectedValuePath="DataPregao"
                        SelectedValue="{Binding FiltroNegocioAnulado.DataPregao}"
                        IsRequired="True"                                              
                                              />
                    <Controls:SinacorButton HorizontalAlignment="Left"
            			Margin="338,0,0,0"
            			Width="95"
            			Content="{DynamicResource Bovespa.Alocacao.Label.Pesquisar}"
            			VerticalAlignment="Top"
            			IsDefault="True"
            			TabIndex="2" 
                        x:Name="btnPesquisar"
                        Click="btnPesquisar_Click"                  
                                            />
                    <Controls:SinacorButton HorizontalAlignment="Left"
            			x:Name="btnNovaPesquisa"
                        Margin="437,0,0,0"
            			Width="106"
            			Content="{DynamicResource Bovespa.Alocacao.Label.NovaPesquisa}"
            			VerticalAlignment="Top"
                        Click="btnNovaPesquisa_Click"                                            
            			TabIndex="3" />
                </Grid>
            </Controls:SinacorExpander>
            <Controls:SinacorExpander Grid.Row="1"
									  HorizontalAlignment="Stretch"
									  VerticalAlignment="Stretch"
									  Header="{DynamicResource Bovespa.Alocacao.Label.NegociosAnulados}"
									  IsExpanded="True" 
									  Margin="0,4,0,0" 
									  AllowExpand="False">
                <Grid>
                    <Controls:SinacorDataGrid x:Name="dtgNegociosAnulados"
                                              ItemsSource="{Binding ListaNegociosAnulados}"
											  HorizontalAlignment="Stretch"
											  Width="Auto" 										
											  IsSynchronizedWithCurrentItem="True" 										
											  VerticalAlignment="Stretch" 										
											  Margin="0,0,0,0"
											  AllowBeginInsert="False" 
                            				  AllowBeginUpdate="False"
											  AllowSave="False" 
											  AllowDelete="False"  
											  TabIndex="4" 
											  IsGroupable="True" >
                        <Controls:SinacorDataGrid.Columns>
                            <Controls:Column Name="Bolsa" 
    										 Title="Bovespa.Alocacao.Label.Bolsa" 
                                             DisplayMemberPath="Bolsa"
                                             HorizontalCellAlignment="Center"
                                             />
                            <Controls:Column Name="Pregao" 
    										 Title="Bovespa.Alocacao.Label.Pregao"
                                             DisplayMemberPath="DataPregao"
                                             HorizontalCellAlignment="Center"
                                             />
                            <Controls:Column Name="NatOperacao" 
    										 Title="Bovespa.Alocacao.Label.NatOper" 
                                             DisplayMemberPath="NaturezaOperacao"
                                             HorizontalCellAlignment="Center"
                                             />
                            <Controls:Column Name="Ativo" 
    										 Title="Bovespa.Alocacao.Label.Ativo" 
                                             DisplayMemberPath="Ativo"
                                             HorizontalCellAlignment="Center"
                                             />
                            <Controls:Column Name="NumeroNegocio" 
    										 Title="Bovespa.Alocacao.Label.NNegocio" 
                                             DisplayMemberPath="Negocio"
                                             HorizontalCellAlignment="Right"
                                             />
                            <Controls:Column Name="Hora" 
    										 Title="Bovespa.Alocacao.Label.Hora" 
                                             DisplayMemberPath="HoraNegocio"
                                             HorizontalCellAlignment="Center"
                                             />
                            <Controls:Column Name="Home" 
    										 Title="Bovespa.Alocacao.Label.Home" 
                                             DisplayMemberPath="Home"
                                             HorizontalCellAlignment="Center"
                                             />
                            <Controls:Column Name="Quantidade" 
    										 Title="Bovespa.Alocacao.Label.Quantidade" 
                                             DisplayMemberPath="Quantidade"
                                             HorizontalCellAlignment="Right"
                                             StringFormat="N2"
                                             Decimals="2"
                                             />
                            <Controls:Column Name="QtdEspecificada" 
    										 Title="Bovespa.Alocacao.Label.QtdEspec" 
                                             DisplayMemberPath="QuantidadeEspecificada"
                                             HorizontalCellAlignment="Right"
                                             StringFormat="N2"
                                             Decimals="2"
                                             />
                            <Controls:Column Name="Preco" 
    										 Title="Bovespa.Alocacao.Label.Preco" 
                                             DisplayMemberPath="Preco"
                                             HorizontalCellAlignment="Right"
                                             StringFormat="N2"
                                             Decimals="2"
                                             />
                            <Controls:Column Name="Ordem" 
    										 Title="Bovespa.Alocacao.Label.Ordem" 
                                             DisplayMemberPath="Ordem"
                                             HorizontalCellAlignment="Right"                                             
                                             />
                            <Controls:Column Name="SubSequencia" 
    										 Title="Bovespa.Alocacao.Label.Subsequencia" 
                                             DisplayMemberPath="SequenciaOrdem"
                                             HorizontalCellAlignment="Right"                                             
                                             />
                            <Controls:Column Name="Cliente" 
    										 Title="Bovespa.Alocacao.Label.Cliente" 
                                             DisplayMemberPath="CodigoCliente"
                                             HorizontalCellAlignment="Center"                                             
                                             />
                            <Controls:Column Name="Origem" 
    										 Title="Bovespa.Alocacao.Label.Origem" 
                                             DisplayMemberPath="Origem"
                                             HorizontalCellAlignment="Center"                                             
                                             />
                            <Controls:Column Name="Contraparte" 
    										 Title="Bovespa.Alocacao.Label.Contraparte" 
                                             DisplayMemberPath="Contraparte"
                                             HorizontalCellAlignment="Right"
                                             />
                        </Controls:SinacorDataGrid.Columns>
                    </Controls:SinacorDataGrid>
                </Grid>
            </Controls:SinacorExpander>
        </Controls:SinacorExpanderContainer>
    </Grid>
</Controls:SinacorWindow>
